package com.sl.au.interceptor;

import org.springframework.data.rest.core.event.AbstractRepositoryEventListener;
import org.springframework.stereotype.Component;
import org.springframework.util.StringUtils;

import com.sl.au.entity.Root;

import java.util.Date;

@Component
public class RepositoryListener extends AbstractRepositoryEventListener<Root> {
    @Override
    protected void onBeforeSave(Root entity) {    	
        super.onBeforeSave(entity);
        entity.setUpdateTime(new Date());
    }
}
